package com.ch.base.action;

import java.sql.Connection;
import java.util.ArrayList;
import java.util.List;

import org.apache.log4j.Logger;

import com.ch.base.element.BaseAction;
import com.ch.base.element.BaseActionForm;

public class TagSampleAction extends BaseAction {
	private final Logger log = Logger.getLogger(this.getClass());
	private List queryList;

	public String execute() throws Exception{
		Connection con = null;
		try {
			con = this.getDBPoolConnection();
			queryList = new ArrayList();
			for(int i=0; i<100; i++){
				String[] array = new String[3];
				 array[0] = String.valueOf(i);
				 array[1] = String.valueOf(i);
				 array[2] = String.valueOf(i);
				 queryList.add(array);
			}
		} catch (Exception e) {
			e.printStackTrace();
			con.rollback();
			errorMsg = e.toString();
			return "exception";
		} finally {
			con.close();
		}
		return SUCCESS;
	}

	public List getQueryList() {
		return queryList;
	}

	public void setQueryList(List queryList) {
		this.queryList = queryList;
	}

	public Logger getLog() {
		return log;
	}


}
